package com.naiterui.ehp.bs.cms.modules.pharmacy.feign;

import java.util.Set;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import com.naiterui.ehp.bp.support.config.FeignConfiguration;
import com.naiterui.ehp.bp.support.exception.BusinessException;

@RequestMapping("/inner/cms/warehouse/goods")
@FeignClient(name = "warehouseGoods", url = "${ehp.domain.b2c}", configuration = FeignConfiguration.class)
public interface WarehouseGoodsFeignClient {

    /**
     * 删除选中商品
     */
    @DeleteMapping("/{warehouseId}")
    void delSelectList(@PathVariable("warehouseId") Long warehouseId, @RequestBody Set<Long> skuIds) throws BusinessException;

    /**
     * 设置选中商品
     */
    @PostMapping("/{warehouseId}")
    void setSelectList(@PathVariable("warehouseId") Long warehouseId, @RequestBody Set<Long> skuIds) throws BusinessException;

}
